<?php
/*
 * 系统内置接口
 */
return array(

    //安装扩展功能模块
    "/extensionApi/installExtension" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "postMustParams" => array(
            "fm_id          | NOEMPTY",
            "fm_name        | NOEMPTY",
            "fm_install_dir | NOEMPTY",
            "fm_dir_name    | NOEMPTY"
        )
    ),

    //事物型操作请求
    "/coreRequest/transaction" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "postMustParams" => array(
            "apiData | NOEMPTY"
        )
    ),

    //新增原子层操作接口
    "/systemApi/addActionPermissions" => array(
        "type"   => "SYSTEM",
        "method" => "POST"
    ),

    //更新原子层操作接口
    "/systemApi/updateActionPermissions" => array(
        "type"   => "SYSTEM",
        "method" => "POST"
    ),

    //更新聚合层层操作接口
    "/systemApi/updateAggregationApiDocs" => array(
        "type"   => "SYSTEM",
        "method" => "POST"
    ),

    //新增业务层操作接口
    "/systemApi/addBussinessApiDocs" => array(
        "type"   => "SYSTEM",
        "method" => "POST"
    ),
    
    //重新生成接口文档配置文件
    "/systemApi/rebuildBussinessApi" => array(
        "type"   => "SYSTEM",
        "method" => "POST"
    ),

    //更新配置文件信息
    "/systemApi/updateConfiguration" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "autoTable" => "sys_atomic_configuration",
        "autoType"  => "U",
        "postMustParams" => array(
            "ac_id | NUMBER"
        )
    ),

    //获取配置文件信息
    "/systemApi/searchConfiguration" => array(
        "type"   => "SYSTEM",
        "method" => "ALL"
    ),

    //重新生成配置文件
    "/systemApi/rebuildConfiguration" => array(
        "type"   => "SYSTEM",
        "method" => "POST"
    ),

    //为组织架构分配角色
    "/systemApi/organizationalAllocationRole" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "postMustParams" => array(
            "osid | NOEMPTY"
        )
    ),

    //为用户分配角色
    "/systemApi/userAllocationRole" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "postMustParams" => array(
            "u_id | NOEMPTY"
        )
    ),

    //为组织架构分配角色（给有继承关系的节点分配父节点的角色）
    "/systemApi/organizationalInheritRole" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "postMustParams" => array(
            "other_node_role | NOEMPTY"
        )
    ),

    //为组织架构分配员工
    "/systemApi/organizationalToEmployee" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "postMustParams" => array(
            "osid | NOEMPTY",
            "employee | NOEMPTY"
        )
    ),

    //用户表查询接口
    "/user/search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"    => "sys_user",
        "autoType"     => "R"
    ),

    //用户角色表信息查询接口
    "/user/user_role_info_search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"    => "system_v_user_role_info",
        "autoType"     => "R"
    ),

    //菜单表查询接口
    "/menu/search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"    => "sys_menu",
        "autoType"     => "R"
    ),

    //角色菜单操作权限查询接口
    "/role/role_menu_info_search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"    => "system_v_role_menu_info",
        "autoType"     => "R"
    ),

    //用户角色表（中间表）更新接口
    "/user_role_middle/update" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_user_role_middle",
        "autoType"     => "U"
    ),

    //用户角色表（中间表）删除接口
    "/user_role_middle/delete" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_user_role_middle",
        "autoType"     => "D"
    ),

    //用户角色表（中间表）新增接口
    "/user_role_middle/add" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"   => "sys_user_role_middle",
        "autoType"     => "C",
        "postMustParams" => array(
            "urm_uid  | NUMBER",
            "urm_orid | NOEMPTY"
        )
    ),

    //用户组织架构表（中间表）更新接口
    "/user_organizational_middle/update" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_user_organizational_middle",
        "autoType"     => "U"
    ),

    //用户组织架构表（中间表）删除接口
    "/user_organizational_middle/delete" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_user_organizational_middle",
        "autoType"     => "D"
    ),

    //用户组织架构表（中间表）查询接口
    "/user_organizational_middle/search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"    => "sys_user_organizational_middle",
        "autoType"     => "R"
    ),

    //用户组织架构表（中间表）新增接口
    "/user_organizational_middle/add" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_user_organizational_middle",
        "autoType"     => "C",
        "postMustParams" => array(
            "uom_osid | NUMBER",
            "uom_uid  | NOEMPTY"
        )
    ),

    //组织架构表查询接口
    "/organizational_structure/search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"    => "sys_organizational_structure",
        "action"	   => "R",
        "autoType"     => "R" 
    ),

    //组织架构表新增接口
	 "/organizational_structure/add" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
       "autoTable"     => "sys_organizational_structure",
       "autoType"      => "C",
       "postMustParams" => array(
           "os_name | NOEMPTY",
           "os_path | NOEMPTY",
           "os_fid  | NUMBER"
       )
   ),

   //组织架构表删除接口
   "/organizational_structure/delete" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_organizational_structure",
        "autoType"     => "D"
    ),

    //组织架构表更新接口
    "/organizational_structure/update" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_organizational_structure",
        "autoType"     => "U"
    ),

    //菜单表新增接口
    "/menu/add" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"   => "sys_menu",
        "autoType"     => "C",
        "postMustParams" => array(
            "m_name | NOEMPTY",
            "m_url | NOEMPTY",
            "m_icon_type  | NUMBER",
            "m_icon | NOEMPTY",
            "m_level | NUMBER",
            "m_fid | NUMBER",
            "m_path | NOEMPTY"
        )
    ),

    //菜单表删除接口
    "/menu/delete" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_menu",
        "autoType"     => "D"
    ),

    //菜单表更新接口
    "/menu/update" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_menu",
        "autoType"     => "U"
    ),

    //菜单操作权限表新增接口
    "/menu_action_permissions_middle/add" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"   => "sys_menu_action_permissions_middle",
        "autoType"     => "C",
        "postMustParams" => array(
            "mapm_mid | NUMBER",
            "mapm_apid | NUMBER"
        )
    ),

    //菜单操作权限表查询接口
    "/menu_action_permissions_middle/search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"   => "sys_menu_action_permissions_middle",
        "autoType"     => "R"
    ),

    //菜单操作权限表查询接口（带接口信息）
    "/menu/menu_action_permissions_info_search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"   => "system_v_menu_action_permissions_info",
        "autoType"     => "R"
    ),

    //菜单操作权限表删除接口
    "/menu_action_permissions_middle/delete" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_menu_action_permissions_middle",
        "autoType"     => "D"
    ),

    //菜单操作权限表更新接口
    "/menu_action_permissions_middle/update" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_menu_action_permissions_middle",
        "autoType"     => "U"
    ),
    
    //公司角色表新增接口
    "/organizational_role/add" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"   => "sys_organizational_role",
        "autoType"     => "C",
        "postMustParams" => array(
            "or_name | NOEMPTY"
        )
    ),

    //公司角色表查询接口
    "/organizational_role/search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"   => "sys_organizational_role",
        "autoType"     => "R"
    ),

    //公司角色表删除接口
    "/organizational_role/delete" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_organizational_role",
        "autoType"     => "D"
    ),

    //公司角色表更新接口
    "/organizational_role/update" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_organizational_role",
        "autoType"     => "U"
    ),


    //组织架构角色表（中间表）新增接口
    "/organizational_role_middle/add" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"   => "sys_organizational_role_middle",
        "autoType"     => "C",
        "postMustParams" => array(
            "orm_osid | NUMBER",
            "orm_orid | NUMBER"
        )
    ),

    //组织架构角色表（中间表）查询接口
    "/organizational_role_middle/search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"    => "sys_organizational_role_middle",
        "autoType"     => "R"
    ),

    //组织架构角色表（中间表）删除接口
    "/organizational_role_middle/delete" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_organizational_role_middle",
        "autoType"     => "D"
    ),

    //组织架构角色表（中间表）更新接口
    "/organizational_role_middle/update" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_organizational_role_middle",
        "autoType"     => "U"
    ),

    //接口请求参数表新增接口
    "/request_parameter/add" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"   => "sys_request_parameter",
        "autoType"     => "C",
        "postMustParams" => array(
            "rp_apid | NUMBER",
            "rp_name | NOEMPTY",
            "rp_is_must | NUMBER",
            "rp_type | NOEMPTY",
            "rp_rule | NOEMPTY",
            "rp_note | NOEMPTY"
        )
    ),

    //接口请求参数表查询接口
    "/request_parameter/search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"   => "sys_request_parameter",
        "autoType"     => "R"
    ),

    //接口请求参数表删除接口
    "/request_parameter/delete" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_request_parameter",
        "autoType"     => "D"
    ),

    //接口请求参数表更新接口
    "/request_parameter/update" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_request_parameter",
        "autoType"     => "U"
    ),

    //角色菜单表（中间表）新增接口
    "/role_menu_middle/add" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_role_menu_middle",
        "autoType"     => "C",
        "postMustParams" => array(
            "rmm_orid | NUMBER",
            "rmm_mid | NOEMPTY"
        )
    ),

    //更新菜单到角色中
    "/systemApi/addMenuToRole" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "postMustParams" => array(
            "roleId | NOEMPTY",
            "roleMenuData | NOEMPTY"
        )
    ),

    //角色菜单表（中间表）查询接口
    "/role_menu_middle/search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"   => "sys_role_menu_middle",
        "autoType"     => "R"
    ),

    //角色菜单表（中间表）删除接口
    "/role_menu_middle/delete" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_role_menu_middle",
        "autoType"     => "D"
    ),

    //角色菜单表（中间表）更新接口
    "/role_menu_middle/update" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_role_menu_middle",
        "autoType"     => "U"
    ),

    //用户表新增接口
    "/user/add" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_user",
        "autoType"     => "C",
        "postMustParams" => array(
            "u_username | NOEMPTY",
            "u_password | NOEMPTY",
            "u_nickname | NOEMPTY",
            "u_phone | NOEMPTY",
            "u_email | NOEMPTY",
            "u_create_time  | NUMBER"
        )
    ),
    
    //用户表删除接口
    "/user/delete" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_user",
        "autoType"     => "D"
    ),

    //用户表更新接口
    "/user/update" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_user",
        "autoType"     => "U"
    ),

    //查询原子层分类
    "/menu_action_permissions_category/search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"    => "sys_action_permissions_category",
        "autoType"     => "R"
    ),

    //新增原子层分类
    "/menu_action_permissions_category/add" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_action_permissions_category",
        "autoType"     => "C",
        "postMustParams" => array(
            "apc_name | NOEMPTY"
        )
    ),

    //删除原子层分类
    "/menu_action_permissions_category/delete" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_action_permissions_category",
        "autoType"     => "D",
        "postMustParams" => array(
            "delete_where | NOEMPTY"
        )
    ),

    //更新原子层分类
    "/menu_action_permissions_category/update" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_action_permissions_category",
        "autoType"     => "U",
        "postMustParams" => array(
            "update_where | NOEMPTY"
        )
    ),

    //获取操作权限列表
    "/action_permissions/search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"    => "sys_action_permissions",
        "autoType"     => "R"
    ),

    //新增业务层接口
    "/bussiness_api_docs/add" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_bussiness_api_docs",
        "autoType"     => "C",
        "postMustParams" => array(
            "bad_name | NOEMPTY",
            "bad_api | NOEMPTY",
            "bad_method | NOEMPTY",
            "bad_response_params | NOEMPTY",
            "bad_badcid | NOEMPTY"
        )
    ),

    //查询业务层接口
    "/bussiness_api_docs/search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"    => "sys_bussiness_api_docs",
        "autoType"     => "R"
    ),

    //删除业务层接口
    "/bussiness_api_docs/delete" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_bussiness_api_docs",
        "autoType"     => "D",
        "postMustParams" => array(
            "delete_where | NOEMPTY"
        )
    ),

    //获取业务层接口分类
    "/bussiness_api_docs_category/search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"    => "sys_bussiness_api_docs_category",
        "autoType"     => "R"
    ),

    //新增业务层接口分类
    "/bussiness_api_docs_category/add" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"    => "sys_bussiness_api_docs_category",
        "autoType"     => "C"
    ),

    //删除业务层接口分类
    "/bussiness_api_docs_category/delete" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"    => "sys_bussiness_api_docs_category",
        "autoType"     => "D",
        "postMustParams" => array(
            "delete_where | NOEMPTY"
        )
    ),

    //更新业务层接口分类
    "/bussiness_api_docs_category/update" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_bussiness_api_docs_category",
        "autoType"     => "U",
        "postMustParams" => array(
            "update_where | NOEMPTY"
        )
    ),

    //获取业务层请求参数信息
    "/sys_bussiness_api_docs_request_parameter/search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"    => "sys_bussiness_api_docs_request_parameter",
        "autoType"     => "R"
    ),

    //获取功能模块
    "/function_module/search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"    => "sys_organizational_function_module",
        "autoType"     => "R"
    ),

    //删除功能模块
    "/function_module/delete" => array(
        "type"         => "SYSTEM",
        "method"       => "POST",
        "autoTable"    => "sys_organizational_function_module",
        "autoType"     => "D"
    ),

    //用户角色表（中间表）查询
    "/user_role_middle/search" => array(
        "type"         => "SYSTEM",
        "method"       => "ALL",
        "autoTable"    => "sys_user_role_middle",
        "autoType"     => "R"
    ),


    //为菜单分配操作
    "/systemApi/addMenuToAction" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "postMustParams" => array(
            "menuId     | NOEMPTY"
        )
    ),


    //安装菜单
    "/extensionApi/installExtensionMenu" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "postMustParams" => array(
            "fm_id | NOEMPTY",
            "fm_install_dir | NOEMPTY"
        )
    ),

    //卸载菜单
    "/extensionApi/uninstallExtensionMenu" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "postMustParams" => array(
            "fm_id | NOEMPTY"
        )
    ),

    //卸载扩展功能模块
    "/extensionApi/unInstallExtension" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "postMustParams" => array(
            "fm_id       | NOEMPTY",
            "fm_dir_name | NOEMPTY"
        )
    ),

    //新增三方扩展模块
    "/sys_organizational_function_module/add" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "autoTable" => "sys_organizational_function_module",
        "autoType"  => "C",
        "postMustParams" => array(
            "fm_fmid        | NOEMPTY",
            "fm_name        | NOEMPTY",
            "fm_install_dir | NOEMPTY",
            "fm_dir_name    | NOEMPTY"
        )
    ),

    //查询三方扩展模块
    "/sys_organizational_function_module/search" => array(
        "type"   => "SYSTEM",
        "method" => "ALL",
        "autoTable" => "sys_organizational_function_module",
        "autoType"  => "R"
    ),

    //更新三方扩展模块信息
    "/sys_organizational_function_module/update" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "autoTable" => "sys_organizational_function_module",
        "autoType"  => "U",
        "postMustParams" => array(
            "update_where | NORMAL" 
        )
    ),

    //删除原子层接口信息
    "/systemApi/deleteActionPermissions" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "postMustParams" => array(
            "ap_id | NORMAL" 
        )
    ),

    //聚合层服务器查询
    "/sys_aggregation_server/search" => array(
        "type"   => "SYSTEM",
        "method" => "ALL",
        "autoTable" => "sys_aggregation_server",
        "autoType"  => "R"
    ),

    //删除聚合层服务器
    "/sys_aggregation_server/delete" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "autoTable" => "sys_aggregation_server",
        "autoType"  => "D",
        "postMustParams" => array(
            "delete_where | NORMAL" 
        )
    ),

    //新增聚合层服务器
    "/sys_aggregation_server/add" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "autoTable" => "sys_aggregation_server",
        "autoType"  => "C"
    ),

    //编辑聚合层服务器
    "/sys_aggregation_server/update" => array(
        "type"   => "SYSTEM",
        "method" => "POST",
        "autoTable" => "sys_aggregation_server",
        "autoType"  => "U"
    ),

    //安装系统内置表和视图
    "/systemApi/installTableAndView" => array(
        "type"   => "SYSTEM",
        "method" => "POST"
    )

);